import 'package:flutter/material.dart';
import 'mvp/page/LoginPage.dart';
import 'package:scoped_model/scoped_model.dart';
import 'package:flutter_localizations/flutter_localizations.dart';

void main() => runApp(ClueApp());

class ClueApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return ScopedModel<CounterModel>(
      model: new CounterModel(appH: 52),
      child: new MaterialApp(
        home: new LoginPage(),
        localizationsDelegates: [
          //此处
          GlobalMaterialLocalizations.delegate,
          GlobalWidgetsLocalizations.delegate,
        ],
        supportedLocales: [
          //此处
          const Locale('zh', 'CH'),
          const Locale('en', 'US'),
        ],
      ),
    );
  }
}

class CounterModel extends Model {
  CounterModel({double appH}) : this._appBarH = appH;
  double _appBarH = 0.0;

  double get appBarH => _appBarH;
}
